package sanrenxing.dayEnd.backRepertoryTotal.service;

import sanrenxing.dayEnd.backRepertoryTotal.domain.CashAccount;
import sanrenxing.dayEnd.backRepertoryTotal.domain.TransferInstruction;

import java.util.List;

/**
 * 划款指令业务层接口
 */
public interface TransferInstructionBiz {
    /**
     * 添加一行数据
     * @param transferInstruction 划款对象
     * @return
     */
    public int add(TransferInstruction transferInstruction);

    /**
     * 删除一行数据
     * @param tranId 划款编号
     * @return
     */
    public int delete(int tranId);

    /**
     * 修改一行数据
     * @param transferInstruction 划款对象
     * @return
     */
    public int update(TransferInstruction transferInstruction);

    /**
     * 按条件分页查询
     * @param rows 行数
     * @param pages 页数
     * @param condition 条件
     * @return
     */
    public List<TransferInstruction> findAll(int rows, int pages, String condition);

    /**
     * 按条件统计记录数
     * @param condition 条件
     * @return
     */
    public int count(String condition);

    /**
     * 获取查询条件
     * @param transferInstruction 划款对象
     * @return
     */
    public String getCondition(TransferInstruction transferInstruction);

    public TransferInstruction selectById(String tranId);

    public CashAccount selectCashById(String caId);
}
